package com.example.entity;

import com.example.dao.UserMapper;
import lombok.Data;
import org.apache.ibatis.session.SqlSession;

@Data
public class Ticket {
    int id;
    int order_id;
    int passenger_id;
    String passenger_name;
    String passenger_type;
    int flightNo;
    String date;
    double price;
    String seat_type;
    String seat;
    String status;  //upcoming、scheduled、completed、cancelled、unpaid、refunded
    String statusText; //即将起飞、计划中、已完成、已取消、待支付、待退款

    public String getTicket_id() {
        return "HL" + date + "-" + String.format("%04d", id);
    }
}
